<template>
  <div class="container">
    <el-row>
      <el-col :span="16">
        <router-view @showContentFuc="sendContentToDetail"></router-view>
      </el-col>
      <el-col :span="8" class="right-download-icon-ad">
        <download-icon></download-icon>
        <div class="right-bottom-ad">
          <img :src="adUrl" alt="">
        </div>
      </el-col>
    </el-row>
  </div>
</template>

<script>
import DownloadIcon from "../components/DownloadIcon";

export default {
  components: {
    DownloadIcon
  },
  data() {
    return {
      adUrl: "",
      newsContent:null,
      parentNewsDetailsID:[]
    };
  },
  mounted() {
    this.axios
      .all([this.getAD()])
      .then(
        this.axios.spread((newsAD) => {
          if (newsAD.data.status) {
            this.adUrl = newsAD.data.data.img;
          } else {
            this.log(newsAD.data.message);
          }
        })
      )
      .catch(err => {
        this.log(err);
      });
  },
  methods: {
    getAD() {
      return this.axios.get("Information/getObtainInformationLogo");
    },
    sendContentToDetail(data) {
      this.$router.push(`/news/${data.id}`);
    }
  }
};
</script>

<style lang="less">
@import url(../assets/css/news.less);
</style>


